package com.useeinfo.oa.modules.maintaining.entity;


import com.useeinfo.framework.extend.entity.SuperClassEntity;
import com.useeinfo.oa.modules.base.entity.DictInfo;
import com.useeinfo.oa.modules.base.entity.Enterprise;
import com.useeinfo.oa.modules.base.entity.Resource;
import com.useeinfo.oa.modules.security.entity.SystemUser;

import javax.persistence.*;
import java.util.HashSet;
import java.util.Set;

/**
 * @Auther: xudong.sun
 * @Date: 2019/1/2 15:11
 * @Description: 维保参与人
 */
@Entity
@Table(name = "maintain_partner")
public class MaintainPartner extends SuperClassEntity<MaintainPartner> {

    /**
     * 申请原因
     */
    private String reason;

    /**
     * 协作类型
     */
    @ManyToOne
    @JoinColumn(name = "teamwork_cat")
    private DictInfo teamworkCat;

    /**
     * 维保单
     */
    @ManyToOne
    @JoinColumn(name = "maintainOrder_id")
    private MaintainOrder maintainOrder;

    /**
     * 我的工时
     */
    private long workingHours;

    /**
     * 参与人
     */
    @ManyToOne
    @JoinColumn(name = "partner_id")
    private SystemUser partner;

    /**
     * 企业
     */
    @ManyToOne
    @JoinColumn(name = "enterprise_id")
    private Enterprise enterprise;



    /**
     * {"snap": ,"content": ""}
     */
    @Column(length = 500)
    private String content;

    public String getReason() {
        return reason;
    }

    public void setReason(String reason) {
        this.reason = reason;
    }

    public DictInfo getTeamworkCat() {
        return teamworkCat;
    }

    public void setTeamworkCat(DictInfo teamworkCat) {
        this.teamworkCat = teamworkCat;
    }

    public MaintainOrder getMaintainOrder() {
        return maintainOrder;
    }

    public void setMaintainOrder(MaintainOrder maintainOrder) {
        this.maintainOrder = maintainOrder;
    }

    public long getWorkingHours() {
        return workingHours;
    }

    public void setWorkingHours(long workingHours) {
        this.workingHours = workingHours;
    }

    public SystemUser getPartner() {
        return partner;
    }

    public void setPartner(SystemUser partner) {
        this.partner = partner;
    }

    public Enterprise getEnterprise() {
        return enterprise;
    }

    public void setEnterprise(Enterprise enterprise) {
        this.enterprise = enterprise;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }
}
